<template>
	<view>
		<!-- 搜索 -->
		<uni-view data-v-cf183850="" class="cu-bar search bg-white">
			<uni-view data-v-cf183850="" class="search-form round">
				<uni-text data-v-cf183850="" class="cuIcon-search">
					<span></span>
				</uni-text>
				<uni-input data-v-cf183850="">
					<div class="uni-input-wrapper">
						<div class="uni-input-placeholder input-placeholder" data-v-cf183850=""></div>
						<!---->
						<form action="" class="uni-input-form"><input v-model="keyword" maxlength="140" step="" enterkeyhint="search" 
								autocomplete="off" type="search" class="uni-input-input" ></form>
					</div>
				</uni-input>
			</uni-view>
			<uni-view data-v-cf183850="" class="action">
				<uni-button data-v-cf183850="" class="cu-btn bg-green shadow-blur round" @click="search1">搜索</uni-button>
			</uni-view>
		</uni-view>

		<view v-for="item,index in list" >
			<video :src="item.videoAddress" controls></video><span @click="goXiangQing(item.videoId,item.goodsId,item.videoAddress)">视频详情</span><span></span>
			
		</view>

<!-- 
		<view v-for="(item,index) in list" class="" @click="goxiangiqng(item.userId)">
			<video :src="item.videoAddress" controls></video>{{item.videoIntroduce}}
		</view> -->
	</view>
</template>

<script>
	export default{
		data(){
			return{
				keyword:'',
				list:[

				]
			
			}
			
		},
		methods:{
			search1(){
				// this.$req.getVideoKeyword(this.keyword).then(res=>{console.log(res)})
				this.$req.getVideoKeyword(this.keyword).then(res=>{
					this.list=res.data.list
				})
			},
			goXiangQing(videoId,goodsId,videoAddress){
				uni.navigateTo({
					url:"../videoDetails/videoDetails?videoId="+videoId+"&goodsId="+goodsId+"&videoAddress="+videoAddress
				})

			}


		}
	}
</script>

<style>
</style>